
public class SimpleNumber {


	public static void main(String[] args) {
		int maxCount = 1000;
		int array[] = new int [maxCount];
		int count = 0;
		
		for (int index = 3; index < maxCount; index += 2){
			if( index < 8 ){
				array[count] = index;
				System.out.println( index );
				count++;
			} 
			else{
				boolean IsSimple=false;
				for(int j = 0; j < count; j++){
					if (index % array[j] != 0){
						IsSimple=true;							
					}
					else{ 
						IsSimple=false;
						break;
					}
					if( IsSimple ){
						array[count] = index;
						System.out.println( index );
						count++;
					}	
				}
			}
		}
	}
}
